package com.swanclouds.redfish.managers.domain;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.swanclouds.model.managers.VirtualMediaVmmControl;
import com.swanclouds.model.managers.VmmControl;
import java.util.List;
import java.util.Map;

/**
 * @author 李文强
 * description
 */

public class VirtualMediaVmmControlModel implements VmmControl {

    /**
     * 虚拟媒体操作类型
     */
    @JsonProperty("vmmControlType")
    private VirtualMediaModel.VmmControlType vmmControlType;

    /**
     * 虚拟媒体镜像uri
     */
    @JsonProperty("Image")
    private String image;

    /**
     * 虚拟媒体 ID
     */
    @JsonProperty("VirtualMediaId")
    private String virtualMediaId;


    @Override
    public VirtualMediaVmmControl toBuilder() {
        return new VirtualMediaVmmControlConterteBuilder();
    }

    public static VirtualMediaVmmControl builder() {
        return new VirtualMediaVmmControlModel().toBuilder();
    }

    public static class VirtualMediaVmmControlConterteBuilder implements  VirtualMediaVmmControl{
        VirtualMediaVmmControlModel  m;

        VirtualMediaVmmControlConterteBuilder(){
            this(new VirtualMediaVmmControlModel());
        }

        VirtualMediaVmmControlConterteBuilder(VirtualMediaVmmControlModel m){
            this.m = m;
        }
        @Override
        public VmmControl build() {
            return m;
        }

        @Override
        public VirtualMediaVmmControl from(VmmControl in) {
            m = (VirtualMediaVmmControlModel) in;
            return this;
        }

        @Override
        public VirtualMediaVmmControl VmmControlType(VirtualMediaModel.VmmControlType virtualMediaVmmControl) {
            m.vmmControlType = virtualMediaVmmControl;
            return this;
        }

        @Override
        public VirtualMediaVmmControl Image(String image) {
            m.image = image;
            return this;
        }

        @Override
        public VirtualMediaVmmControl VirtualMediaId(String virtualMediaId) {
            m.virtualMediaId = virtualMediaId;
            return this;
        }
    }

    @Override
    public String getContext() {
        return null;
    }

    @Override
    public Map<String, Object> getActions() {
        return null;
    }

    @Override
    public Map<String, Object> getOem() {
        return null;
    }

    @Override
    public String getDataId() {
        return null;
    }

    @Override
    public String getType() {
        return null;
    }

    @Override
    public String getId() {
        return null;
    }

    @Override
    public String getName() {
        return null;
    }

    @Override
    public List<String> getMediaTypes() {
        return null;
    }

    @Override
    public Boolean getWriteProtected() {
        return null;
    }

    @Override
    public String getImageName() {
        return null;
    }

    @Override
    public String getUserName() {
        return null;
    }

    @Override
    public String getPassword() {
        return null;
    }

    @Override
    public Boolean getInserted() {
        return null;
    }

    @Override
    public String getConnectedVia() {
        return null;
    }

    @Override
    public String getImage() {
        return this.image;
    }

    @Override
    public VirtualMediaModel.VmmControlType getVmmControlType() {
        return this.vmmControlType;
    }

    @Override
    public String getVirtualMediaId() {
        return this.virtualMediaId;
    }

    @Override
    public String toString() {
        return "{" +
                "vmmControlType='" + vmmControlType + '\'' +
                ", image='" + image + '\'' +
                ", virtualMediaId='" + virtualMediaId + '\'' +
                '}';
    }
}
